implement importChanges optimisaton (not used yet)
authorJoey Hess <joeyh@joeyh.name>
Wed, 31 May 2023 19:45:23 +0000 (15:45 -0400)
committerJoey Hess <joeyh@joeyh.name>
Wed, 31 May 2023 20:01:34 +0000 (16:01 -0400)
commitc6acf574c715dc3abf2c8fa0fbd65f40e13e4665
tree4d863afd4913331f9cf4eed00be139a628d879e6
parent72981235204b5065676880be42cf64079efae881
implement importChanges optimisaton (not used yet)

For simplicity, I've not tried to make it handle History yet, so when
there is a history, a full import will still be done. Probably the right
way to handle history is to first diff from the current tree to the last
imported tree. Then, diff from the current tree to each of the
historical trees, and recurse through the history diffing from child tree
to parent tree.

I don't think that will need a record of the previously imported
historical trees, and so Logs.Import doesn't store them. Although I did
leave room for future expansion in that log just in case.

Next step will be to change importTree to importChanges and modify
recordImportTree et all to handle it, by using adjustTree.

Sponsored-by: Brett Eisenberg on Patreon
Annex/Import.hs
Annex/Locations.hs
Command/Import.hs
Command/Sync.hs
Git/FilePath.hs
Logs/Import.hs [new file with mode: 0644]
Types/Import.hs
git-annex.cabal